package pl.dalkia.services.scanner.services.matcher;

import java.util.regex.Matcher;

public class SpecificConditionLogReverseMatcher extends
		AbstractConditionLogMatcher implements Matchable {

	public SpecificConditionLogReverseMatcher(String specificPattern) {
		super(specificPattern);
	}

	@Override
	public boolean match(String input) {
		if (isReadyForMatching(input)) {
			return performMatch(input);
		}
		return false; 
	}

	private boolean performMatch(String input) {
		Matcher matcher = super.pattern.matcher(input);
		return matcher.find();
	}
}
